	<?php 
		$ci= &get_instance();
		$listPrize = $ci->prize_entity->getArrayListOfPrize($tournament_id);
	?>
	
	<div class="clrboth"></div>
<table>	
	<thead>
		<th><div class="grid1"><span class="bold" style="font-weight:bold;">Rank</span></div></th>
		<th><div class="grid1"><span class="bold" style="font-weight:bold;">Prize</span></div></th>
		<th><div class="grid1"><span class="bold" style="font-weight:bold;">Image</span></div></th>
		<th><div class="grid1"><span class="bold" style="font-weight:bold;">Logo</span></div></th>
		<th><div class="grid1"><span class="bold" style="font-weight:bold;">Value</span></div></th>
		<th><div class="grid1"><span class="bold" style="font-weight:bold;">Delivery Status</span></div></th>
		<th><div class="grid2"><span class="bold" style="font-weight:bold;">Proof</span></div></th>
		<th><div class="grid2"><span class="bold" style="font-weight:bold;">Shipping date</span></div></th>
		<th><div class="grid2"><span class="bold" style="font-weight:bold;">Manage</span></div></th>
	</thead>
	<div class="clrboth"></div>
	<tbody>
		<?php foreach( $listPrize as $item ): ?>
			<?php 
				$PRIZE = $ci->prize_entity->init('id',$item->id);
			?>
		<tr>	
			<td><div class="grid1"><?php echo $PRIZE->getRank(); ?></div></td>
			<td><div class="grid1"><?php echo $PRIZE->getPrizeName(); ?></div></td>
			<td><div class="grid1"><?php echo thumb($PRIZE->getPrizeImage(),40,40); ?></div></td>
			<td><div class="grid1"><?php if($PRIZE->getLogo()) echo thumb($PRIZE->getLogoImage(),30,30); ?></div></td>
			<td><div class="grid1"><?php echo $PRIZE->getValue(); ?></div></td>
			<td><div class="grid1"><?php echo $PRIZE->getDeliveryStatus(); ?></div></td>
			<td><div class="grid2"><?php echo thumb($PRIZE->getProofImage(),40,40,true); ?></div></td>
			<td><div class="grid2"><?php if($PRIZE->getShippingDate()) echo sysDateTimeFormat( $PRIZE->getShippingDate() ,'Y-m-d' ); ?></div></td>
			
			<td><div class="grid2">
				<a href="javascript:void(0);" onclick="prize_edit(<?php echo $PRIZE->getId();?>)"><?php echo lang('dataman.edit');?></a>
				&nbsp;|&nbsp;
				<a href="javascript:void(0);" onclick="prize_delete(<?php echo $PRIZE->getId();?>)" >Delete</a>
			</div></td>
			<div class="clrboth"></div>
		</tr>		
		<?php endforeach; ?>
	</tbody>
</table>		

